The present invention relates to a reading method and a reader for an optical code.
Readers are known for optical codes, in particular bar codes, in which a photoemitter (which for example comprises one or more LEDs, a laser beam source etc) illuminates an optical code and a photoreceiver (for example a photodiode, a series of photodiodes, a telecamera etc) detects at least part of the light radiation diffused by the code, in order to generate in response an electrical signal which is modulated by the different color elements of the code. This signal is amplified and decoded, thus extracting the alphanumerical data associated with the optical code itself.
Some types of readers read the code by means of manual activation by an operator. On the other hand, other types of readers remain continually in an operating state in which all the above-described reading operations are carried out. In other words, when they are switched on, these readers remain indefinitely in a single operating state, irrespective of the actual use of the reader itself or of any alterations in the operative environment in which the reader is disposed.
This operating method is not very advantageous since in specific operating conditions, for example when the reader is not being used, it would be advantageous to be able to modify the operating state of the reader, without manual intervention by the operator.
The main object of the present invention is to provide a reading method and a reader for an optical code, which can alter its own operating state fully automatically.
More specifically, in known portable readers, the electrical signal is amplified by means of an amplifier circuit with a fixed gain, or with automatic gain control.
As is known, the automatic gain control devices increase the amplification gain in the presence of a low or zero-level signal output from the amplifier and decrease the amplification gain in the presence of an output signal which has a high level, in order to keep the level of the output signal substantially constant.
In the operating condition in which the radiation emitted by the photoemitter is not reflected by any surface close to the reader, the luminous radiation received by the photoreceiver is negligible and the signal present at the output of the amplifier is extremely low. In this operating condition, automatic gain control applied to the amplifier would force the gain of the amplifier towards very high values and the low noise voltage which is always present at the input of the amplifier would be greatly amplified, producing at the output a high voltage value similar to that which is detected in normal operating conditions, when the luminous radiation emitted by the photoemitter is diffused by a white surface.
It is clear that such kind of readers would not be of practical use since, in the presence of low or zero radiation detected, the amplifier would immediately increase its own gain and would become saturated.
In addition, some optical code readers of the portable type generally comprise a case which can be grasped, which at one of its ends holds the photoemitters and photoreceivers. For such readers, the zero or extremely low input signal condition occurs whenever the reader does not face and at a short distance, a reflective surface, since the radiation emitted by the photoemitter, which has low emission power, is lost in the space which surrounds the reader and is not detected by the photoreceiver.
A further object of the present invention is to provide a method and a reader for an optical code, in which alteration of the operating state of the reader allows automatic gain control to function in all operating conditions.
This invention can thus advantageously be used in the field of portable readers.
The above-described object is achieved by the present invention in that it relates to a method for reading an optical code by means of a reader which comprises photoemitter means, photoreceiver means and processor means, characterised in that it comprises the following steps: emitting a radiation towards the exterior of the reader; detecting the presence of at least one operating condition of the said reader; activating a first operating mode in the absence of the said operating condition of the said reader; and activating a second operating mode on detection of the said operating condition.
In this way, the code reader can recognise at least one operating condition, for example non-use and can thus alter its own operating state fully automatically.
More specifically, the said reader also comprises amplifier means with automatic gain control and corresponding to the said first operating mode the said automatic gain control is inhibited, whereas corresponding to the said second operating mode, the said automatic gain control is activated.
In addition, the said first operating mode comprises at least one energy-saving step.
In this way, the automatic gain control is switched on fully automatically before the reader reads the code. Similarly, if the aforementioned operating condition is not present, the automatic gain control is switched off, such that it cannot be activated inappropriately and consequently saturate the amplifier. When the reader is not reading, an energy saving strategy is also implemented in order to prevent the batteries of The reader from being discharged quickly.